﻿Imports TodoMicroSolutionPackV1.bl.bo
Namespace bl
    Public MustInherit Class Rule
        Private _description As String
        Private _propertyName As String

        Public Sub New(ByVal propertyName As String, ByVal brokenDescription As String)
            _propertyName = propertyName
            _description = brokenDescription
        End Sub

        Public Property description As String
            Get
                Return _description
            End Get
            Set(ByVal value As String)
                _description = value
            End Set
        End Property

        Public Property propertyName As String
            Get
                Return _propertyName
            End Get
            Set(ByVal value As String)
                _propertyName = value
            End Set
        End Property

        Public MustOverride Function validateRule(ByRef businessObject As genericBusinessObject) As Boolean

        Public Overrides Function ToString() As String
            Return _description
        End Function

        Public Overrides Function GetHashCode() As Integer
            Return ToString.GetHashCode()
        End Function
    End Class
End Namespace

